package cn.wolfcode.productdemo.product_fifter;

import org.apache.rocketmq.spring.core.RocketMQTemplate;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Description: tag标签过滤
 * @Author: 伍家钰
 * @Date: 2020/9/4 13:33
 * @Version: 1.0
 */
@RestController
public class TagFilterController {
    @Autowired
    private RocketMQTemplate template;

    @RequestMapping("tagFilter")
    public String tagFilter(String msg, String tag) {
        template.syncSend("01-tag-Filter:" + tag, msg);
        System.out.println("发送消息成功:" + msg);
        return "success";
    }
}
